const util = require('./utils/util.js')
App({
  onLaunch: function() {
    wx.login({
      success: function(res) {
        // util.getAjax("https://weixin.qiyehuo.com/api/getToken", {
        //   code: res.code, secret: 'b33ebee59e7d5e79ceed709fa6e5bcd7', login_type:'wx_app'}, (res)=>{
        //   if (res.data.code=="1000"){
        //     wx.setStorageSync({ unionId: res.data.data.unionId});
        //   } else if (res.data.code == "1001"){
        //     console.log(res);
        //     wx.navigateTo({
        //       url:"/pages/binding/binding"
        //     })
        //   }
        // });
      }
    })
   
  },
  
  globalData: {
    userInfo: null,
    SearchMusic:'https://api.apiopen.top/searchMusic',
    qiyehuo:'https://weixin.qiyehuo.com/api/get_param'
  }
  



})